package cn.tedu.community.commons.pojo.returnHome.dto;

import lombok.Data;

import javax.validation.constraints.NotBlank;
import javax.validation.constraints.NotEmpty;
import javax.validation.constraints.NotNull;
import javax.validation.constraints.Pattern;
import java.io.Serializable;
import java.sql.Date;
import java.time.LocalDateTime;

@Data
public class ReturnHomeDTO implements Serializable {
    /**
     * 出发地点
     */
    @Pattern(regexp = "^([\\u4E00-\\u9FA5A-Za-z0-9_]+(省|市|区|县|道|路|街)){2,30}$",
            message = "请填写正确的出发地点！例如x省x市x区x县x道x路x街")
    private String startPlace;

    /**
     * 返乡时间
     */
    @NotBlank(message = "请选择返乡时间！")
    private String returnDate;

    /**
     * 体温
     */
    @Pattern(regexp = "((^3[5-9])(\\.\\d{1})?$|^(4[0-5])(\\.\\d{1})?$)",
    message = "请输入35-45之间的摄氏度！")
    private String temperature;

    /**
     * 身体状态
     */
    @Pattern(regexp = ".{1,40}",
            message = "请输入1-40个字符的身体状态！")
    private String bodyStatus;

    /**
     * 近十五天轨迹
     */
    @Pattern(regexp = ".{1,50}",
            message = "请输入1-50个字符的近十五天轨迹！")
    private String halfMonthPast;

    /**
     * 核酸报告(图片)
     */
    @NotBlank(message = "请上传核酸检测截图！")
    private String nucleicReport;

    /**
     * 经过疫区
     */
    @Pattern(regexp = ".{1,40}",
            message = "请输入1-40个字符的经过疫区地名！没有则填写'无'")
    private String throughDangerArea;

}
